/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

package superuser;

import gui.LoginDialog;
import java.rmi.registry.LocateRegistry;
import java.rmi.registry.Registry;
import java.util.logging.Level;
import java.util.logging.Logger;
import utils.ServerInterface;

/**
 *
 * @author shaowei
 */
public class Superuser {

    /**
     * @param args the command line arguments
     */
    public static void main(String[] args) {

        try {
            
            Registry registry = LocateRegistry.getRegistry("127.0.0.1", 12345) ; 
            ServerInterface server = (ServerInterface) registry.lookup("OnlineStoreServer") ;
            
            new SuperuserGUI(server) ;
        }
        catch (Exception ex) {
            Logger.getLogger(LoginDialog.class.getName()).log(Level.SEVERE, null, ex) ;
        }
    }
    
}
